<?php

use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateProjectsTable extends Migration {

	/**
	 * Run the migrations.
	 *
	 * @return void
	 */
	public function up()
	{
		Schema::create('projects',function($table){
			$table->engine = 'InnoDB';
			$table->increments('id');
			$table->integer('user_id');
			$table->string('name')->default('');
			$table->string('home_url')->default('http://');
			$table->string('doc_url')->default('http://');
			$table->string('download_url')->default('http://');
			$table->string('license')->default('GPL');
			$table->text('detail')->default('');
			$table->tinyInteger('status')->default(0);
			$table->timestamps();
		});
	}

	/**
	 * Reverse the migrations.
	 *
	 * @return void
	 */
	public function down()
	{
		Schema::drop('projects');
	}

}
